import request from '../utils/request'
// 获取文章数据接口
export const articleListAPI = (channelId, pre_timestamp) => {
  return request({
    url: '/v1_0/articles',
    params: {
      channel_id: channelId,
      timestamp: pre_timestamp || new Date().getTime() + ''
    }
  })
}
// 获取指定文章详情
export const articleDetailAPI = ({ id }) => {
  return request({
    url: `/v1_0/articles/${id}`
  })
}
// 举报接口
export const articleReportsAPI = ({ artId, type }) => {
  return request({
    url: '/v1_0/article/reports',
    method: 'POST',
    data: {
      target: artId,
      type: type,
      remark: type === '0' ? '我是附加说明哦' : null
    }
  })
}
